/*
 * 版权所有 (C) 2015 知启蒙(ZHIQIM) 保留所有权利。[欢迎加盟知启蒙，一起邂逅框架梦]
 * 
 * https://www.zhiqim.com/gitcan/zhiqim/zhiqim_account.htm
 *
 * Licensed under the Apache License, Version 2.0 (the "License");
 * you may not use this file except in compliance with the License.
 * You may obtain a copy of the License at
 *
 * http://www.apache.org/licenses/LICENSE-2.0
 *
 * Unless required by applicable law or agreed to in writing, software
 * distributed under the License is distributed on an "AS IS" BASIS,
 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
 * See the License for the specific language governing permissions and
 * limitations under the License.
 */
package org.zhiqim.account.dbo.user;

import java.io.Serializable;
import java.sql.Timestamp;

import org.zhiqim.kernel.annotation.AnAlias;
import org.zhiqim.kernel.annotation.AnNew;
import org.zhiqim.kernel.json.Jsons;
import org.zhiqim.orm.annotation.*;

/**
 * 用户支付宝交易 对应表《USER_TRADE_ALIPAY》
 */
@AnAlias("UserTradeAlipay")
@AnNew
@AnTable(table="USER_TRADE_ALIPAY", key="TRADE_ID", type="InnoDB")
public class UserTradeAlipay implements Serializable
{
    private static final long serialVersionUID = 1L;

    @AnTableField(column="USER_ID", type="long", notNull=true)    private long userId;    //1.用户编号
    @AnTableField(column="TRADE_ID", type="long", notNull=true)    private long tradeId;    //2.交易编号
    @AnTableField(column="TRADE_AMOUNT", type="int", notNull=true)    private int tradeAmount;    //3.交易金额，单位：分
    @AnTableField(column="TRADE_SUBJECT", type="string,64", notNull=true)    private String tradeSubject;    //4.交易标题
    @AnTableField(column="TRADE_STATUS", type="string,32", notNull=true)    private String tradeStatus;    //5.交易状态
    @AnTableField(column="TRADE_CREATED", type="datetime", notNull=true)    private Timestamp tradeCreated;    //6.交易创建时间
    @AnTableField(column="TRADE_CALLBACK", type="string,50", notNull=true)    private String tradeCallback;    //7.交易回调
    @AnTableField(column="TRADE_ORDER_ID", type="long", notNull=false)    private long tradeOrderId;    //8.交易订单编号
    @AnTableField(column="TRADE_NO", type="string,64", notNull=false)    private String tradeNo;    //9.支付宝交易号
    @AnTableField(column="TRADE_ACCOUNT", type="string,100", notNull=false)    private String tradeAccount;    //10.支付宝买家账号
    @AnTableField(column="TRADE_NOTIFIED", type="datetime", notNull=false)    private Timestamp tradeNotified;    //11.支付宝通知时间
    @AnTableField(column="TRADE_NOTIFY_DESC", type="string,4000", notNull=false)    private String tradeNotifyDesc;    //12.支付宝通知描述
    @AnTableField(column="TRADE_RETURN_DESC", type="string,4000", notNull=false)    private String tradeReturnDesc;    //13.支付宝页面返回参数

    public String toString()
    {
        return Jsons.toString(this);
    }

    public long getUserId()
    {
        return userId;
    }

    public void setUserId(long userId)
    {
        this.userId = userId;
    }

    public long getTradeId()
    {
        return tradeId;
    }

    public void setTradeId(long tradeId)
    {
        this.tradeId = tradeId;
    }

    public int getTradeAmount()
    {
        return tradeAmount;
    }

    public void setTradeAmount(int tradeAmount)
    {
        this.tradeAmount = tradeAmount;
    }

    public String getTradeSubject()
    {
        return tradeSubject;
    }

    public void setTradeSubject(String tradeSubject)
    {
        this.tradeSubject = tradeSubject;
    }

    public String getTradeStatus()
    {
        return tradeStatus;
    }

    public void setTradeStatus(String tradeStatus)
    {
        this.tradeStatus = tradeStatus;
    }

    public Timestamp getTradeCreated()
    {
        return tradeCreated;
    }

    public void setTradeCreated(Timestamp tradeCreated)
    {
        this.tradeCreated = tradeCreated;
    }

    public String getTradeCallback()
    {
        return tradeCallback;
    }

    public void setTradeCallback(String tradeCallback)
    {
        this.tradeCallback = tradeCallback;
    }

    public long getTradeOrderId()
    {
        return tradeOrderId;
    }

    public void setTradeOrderId(long tradeOrderId)
    {
        this.tradeOrderId = tradeOrderId;
    }

    public String getTradeNo()
    {
        return tradeNo;
    }

    public void setTradeNo(String tradeNo)
    {
        this.tradeNo = tradeNo;
    }

    public String getTradeAccount()
    {
        return tradeAccount;
    }

    public void setTradeAccount(String tradeAccount)
    {
        this.tradeAccount = tradeAccount;
    }

    public Timestamp getTradeNotified()
    {
        return tradeNotified;
    }

    public void setTradeNotified(Timestamp tradeNotified)
    {
        this.tradeNotified = tradeNotified;
    }

    public String getTradeNotifyDesc()
    {
        return tradeNotifyDesc;
    }

    public void setTradeNotifyDesc(String tradeNotifyDesc)
    {
        this.tradeNotifyDesc = tradeNotifyDesc;
    }

    public String getTradeReturnDesc()
    {
        return tradeReturnDesc;
    }

    public void setTradeReturnDesc(String tradeReturnDesc)
    {
        this.tradeReturnDesc = tradeReturnDesc;
    }

}
